<include file="Common:head" />
<body class="easyui-layout">
    <div data-options="region:'north',title:'',split:false,border:false" style="background-color: rgb(102, 102, 102);height:80px;">
    	<include file="Common:header" />
    </div>
    <div data-options="region:'south',title:'',split:false,border:false" style="height:40px;background-color:#eee;"></div>
    <div data-options="region:'west',title:'Menu',split:false" style="width:200px;">
    	<ul id="west_menu">
    	</ul>
    </div>
    <div data-options="region:'center',title:''" style="background:#eee;">
	   	<div id="center_tabs">
		</div>
    </div>
    <script type="text/javascript">
	    $('#center_tabs').tabs({
	        border:false,
	        fit:true,
	        onSelect:function(title){
	            
	        }
	    });
	    $('#center_tabs').tabs('add',{
	        title:'welcome',
	        content:'',
	        closable:false
	    });
	    $('#west_menu').tree({
	        url:'<{:U('Admin/Index/menu')}>',
	        lines:true,
	        onClick:function(node){
	        	if(typeof(node.src) != 'undefined'){
	        		if($('#center_tabs').tabs('exists', node.text)){
	        			$('#center_tabs').tabs('select', node.text);
	        		}
	        		else{
		        		$('#center_tabs').tabs('add',{
		        	        id:node.attrid,
		        			title:node.text,
		        	        closable:true,
		        	        href:node.src,
		        	        cache:true
		        	    });
	        		}
	        	}
	        }
	    });
    </script>
</body>
</html>